class Dog {

    //成员变量
    public  int age;
    public   String type;
    public   String name;


    public int num;

    //构造方法
    public Dog(int a,String b,String c){
        this.age = a;
        this.type = b;
        this.name = c;

    }


    //成员方法
   public void setDog(int a, String t, String n){
      this.age = a;
      this.type = t;
      this.name = n;

   }

    @Override
    public String toString() {
        return "Dog{" +
                "age=" + age +
                ", type='" + type + '\'' +
                ", name='" + name + '\'' +
                '}';
    }

    //public  static void printDog(){
//    System.out.println("age: "+ age);
//    System.out.println("type: "+ type);
//    System.out.println("name: "+ name);
//}


    public void bark() {
        System.out.println(name + "在汪汪汪");
    }

    public void sleep() {
        System.out.println(name + "在睡觉");
    }

}